import React, { Component } from 'react'
import { Route } from "react-router-dom";
import './css/home.css'
import { isLogin } from "../../api/index"
import {
  Login,
  Reg,
  Tab
} from "../../components";

class Home extends Component {
  componentDidMount() {
    isLogin().then(code => {
       
    })
  }
  render() {
    return (
      <>
      <div className="home">
        <div className="login"> 
          <Route path="/" exact component={Login} />
        </div>
        <div className="reg">
          <Route path="/reg" exact component={Reg} />
        </div>
        <div className="main">
          <Route path="/main" component={Tab}  />
        </div>
      </div>
      </>
    );
  }
}

export default Home;
